import { Uri } from "vscode";
import { ExecutionInfo, IConfigurationService, Product } from "../common/types";
import { ILinterInfo, LinterId } from "./types";

export class LinterInfo implements ILinterInfo {
    private _id: LinterId;

    private _product: Product;

    private _configFileNames: string[];

    constructor(
        product: Product,
        id: LinterId,
        protected configService: IConfigurationService,
        configFileNames: string[] = [],
    ) {
        this._product = product;
        this._id = id;
        this._configFileNames = configFileNames;
    }
    public get id(): LinterId {
        return this._id;
    }

    public get product(): Product {
        return this._product;
    }

    public get pathSettingName(): string {
        return `${this.id}Path`;
    }

    public get argsSettingName(): string {
        return `${this.id}Args`;
    }

    public get configFileNames(): string[] {
        return this._configFileNames;
    }

    public get enabledSettingName(): string {
        return `${this.id}Enabled`;
    }

    enableAsync(enabled: boolean, resource?: Uri): Promise<void> {
        throw new Error("Method not implemented.");
    }
    isEnabled(resource?: Uri): boolean {
        throw new Error("Method not implemented.");
    }
    pathName(resource?: Uri): string {
        throw new Error("Method not implemented.");
    }
    linterArgs(resource?: Uri): string[] {
        throw new Error("Method not implemented.");
    }
    getExecutionInfo(customArgs: string[], resource?: Uri): ExecutionInfo {
        throw new Error("Method not implemented.");
    }
}